package learning.data.document;

import learning.util.SparseVector;

public class TreeDocument implements IDocument {
	
	public String[] tokens;
	public ExampleClass[] classes;
	
	public TreeDocument(String[] tokens, ExampleClass[] classes) {
		this.tokens = tokens;
		this.classes = classes;
	}
	
	public int getDependencyAttribute(int i) {
		return -1;
	}
	
	public static class ExampleClass {
		public String name; // e.g. "token", "phrase" "sentence", "article"		
		public int [][] spans; // dimensions: {exampleId} x {begin,end}, which tokens are spanned
		public SparseVector[] features;
		public int[] labels;
		public String[] tokens;
		
		public ExampleClass(String name, int[][] spans, SparseVector[] features, int[] labels,
				String[] tokens) {
			this.name = name;
			this.spans = spans;
			this.features = features;
			this.labels = labels;
			this.tokens = tokens;
		}
	}
}
